#include <ut/UnitTest.h>
#include <illib/Log.h>
#include <ilrt/Interpreter.h>
#include <ilrt/Runtime.h>

using namespace ilrt;

namespace ilrt_ut{
	void Interpreter_ut() {
		{
			Runtime runtime;
			Instruction instructions[] = {Instruction(Instruction::ONOP, Instruction::PNONE)};
			Interpreter i;
			StackFrame * frame = i.stack().push(runtime.types.InterpreterStack);
			InstructionArray program(instructions, sizeof(instructions)/sizeof(instructions[0]));
			frame->program(&program);
			i.run(1);
			i.stack().clear(runtime.types.InterpreterStack);
		}
	}
};

